﻿using MDT.LifeSewagePlatform.Conmmon;
using MDT.LifeSewagePlatform.Entity;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Text;
using System.Threading.Tasks;

namespace MDT.LifeSewagePlatform.IRepository
{
    public interface IDrugDetailRepository: IBaseRepository<DrugDetailEntity>
    {
        public IQueryable<DrugDetailUnion> GetDrugDetails(Expression<Func<DrugDetailUnion, bool>> expression);
        public Task<DrugDetailEntity> GroupByAverage(IQueryable<DrugDetailUnion> drugDetailUnion);

        public  Task<Dictionary<int, double>> GroupByAverage(IQueryable<DrugDetailUnion> drugDetailUnion, eGroupGetDateType eGroupType);
       
        public  Task<List<DrugDetailEntity>> GroupByDrugDetailAverage(IQueryable<DrugDetailUnion> drugDetailUnion, eGroupGetDateType eGroupType);

        public Task<Dictionary<string, double>> GroupByPlaceAverage(IQueryable<DrugDetailUnion> drugDetailUnion);

        public  Task<List<DrugDetailEntity>> GroupByDrugDetailPlaceAverageAsync(IQueryable<DrugDetailUnion> drugDetailUnion);

        public IQueryable<DrugDetailEntity> GroupByDrugDetailPlaceAverage(IQueryable<DrugDetailUnion> drugDetailUnion);
        public Task<List<PieView>> GetTimeGroupByQuarterOrMonth(IQueryable<DrugDetailEntity> drugs, int eGroupType);

        public  Task<DateDto> GroupByDate(IQueryable<DrugDetailUnion> drugDetailUnion);

        public  Task<List<DrugDetailReprot>> GroupDrugDetails(IQueryable<DrugDetailUnion> drugDetails);


    }
}
